package gam.t1.conf;

import org.bukkit.configuration.file.YamlConfiguration;
import org.bukkit.plugin.Plugin;
import org.jetbrains.annotations.Nullable;

import java.io.File;
import java.io.IOException;
import java.util.List;

public final class TextConfig {
    private static final String FILE = "config.yml";
    public static List<String> TEXTS;
    public static boolean sync = false;
    public static String prefix ;
    public static void load(Plugin plugin) throws IOException {
        File var1 = new File(plugin.getDataFolder(),FILE);
        if (!var1.exists()){
            plugin.saveResource(FILE,false);
        }
        YamlConfiguration var2 = YamlConfiguration.loadConfiguration(var1);
        TEXTS = var2.getStringList("joincontext");
        sync = var2.getBoolean("urlcheck");
        prefix = var2.getString("chartranslate");
    }
}
